create  table jms_dm.dm_network_arrival_union_deliver_sum_dt
(
agent_code      varchar(100) COMMENT '代理区code' ,
provider_id     varchar(100) COMMENT '省份id' ,
city_id         varchar(100) COMMENT '城市id' ,
scan_site_code  varchar(100) COMMENT '网点code' ,
agent_name      varchar(100) COMMENT '代理区名字' ,
provider_desc   varchar(100) COMMENT '省份' ,
city_desc       varchar(100) COMMENT '城市' ,
name            varchar(100) COMMENT '网点名字' ,
ordersource_name  varchar(100) COMMENT '订单来源' ,
waybill_num          bigint COMMENT '运单总量' ,
arrival_deliver_num  bigint COMMENT '到出一体总量' ,
after_deliver_num    bigint COMMENT '稍后出仓总量' ,
date_time date COMMENT '业务日期' )
ENGINE=OLAP
DUPLICATE KEY(agent_code,provider_id,city_id,scan_site_code)
comment '网点到出一体监控'
PARTITION BY RANGE (date_time) (
   START ("2022-11-04") END ("2022-12-15") EVERY (INTERVAL 1 day))DISTRIBUTED BY HASH(scan_site_code) BUCKETS 4
PROPERTIES (
"replication_num" = "3",
"dynamic_partition.enable" = "true",
"dynamic_partition.time_unit" = "DAY",
"dynamic_partition.time_zone" = "Asia/Shanghai",
"dynamic_partition.start" = "-180",
"dynamic_partition.end" = "3",
"dynamic_partition.prefix" = "p",
"dynamic_partition.buckets" = "4",
"in_memory" = "false",
"storage_format" = "V2"
);